Attachments

Download a File from the File System

Code Customization
Download a File from the File System (Not Applicable To Mobile)
Description:

This customization downloads a file from the application servers file system and saves it on the user's local system. This customization is useful for downloading Microsoft Word document, image and PDF files that are not stored in a database.

Note: This customization assumes that the file exists in the Data subfolder on the application server.

Procedure:

Step 1:  In Iron Speed Designer, switch to Layout Editor. Then select the Buttons region in a table panel.

Step 2:  Drag and drop a Button (Themed) from the Toolbox to an empty cell.

Remember the name of the button because you need to know this to select a value for the button control variable in the Code Customization Wizard. This customization will work only with Iron Speed Designer Button controls.

Step 3:  Set the button text and tool tip text properties for the button in Page Properties window.

Step 4:  Go to the Attributes tab in the button's Page Properties and add "PostBack" pass-through attribute with value "True". Add this attribute only if the button is inside a table or record control whose SmoothPanelUpdate pass-through attribute is true.

Step 5:  Build the application.

Step 6:  Replace the file name "myfile.txt" with your file name which exists in the Data subfolder.

Step 7:  Use this wizard to add code customization that handles the OnClick event for the custom button.

Step 8:  Build and run the application.

Disclaimer:
Customizations included in this wizard are provided as a sample to demonstrate a feature, and may work only in specific situations. The Iron Speed Designer support team cannot assist in the resolution of problems which may occur as a result of customizing your application or modifying a customization to fit a particular purpose.

Terms of Service Privacy Statement